<template>
  <div>
    <Banner :bannerList='bannerList'></Banner>
    <List :listLen='list.length' :total='total'>
      <van-cell slot="" v-for="item in list" :key="item" :title="item.n" />
    </List>
    <!-- <div v-for='(item) in list' :key="item.id">
      {{item.name}}
    </div> -->
  </div>
</template>

<script>
import { mapActions, mapState } from "vuex";
import Banner from '@/components/Banner'
import List from '@/components/List'
export default {
  components: {
    Banner,
    List
  },
  mounted() {
    // console.log(this);
    this.getList();
  },
  computed: {
    ...mapState(["list", "bannerList"]),
  },
  methods: {
    ...mapActions(["getList"]),
  },
};
</script>

<style>
</style>